A rotary encoder is an electro-mechanical device that converts the angular position of a shaft or an axle of a rotary motor to an analog or a digital code indicative of the angular position. Encoder feedback may be used to ensure synchronization of motor stator and rotor positions to drive-supplied current.